<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>interactive</title>
</head>
<body>
<canvas id="canvasBox" width="400" height="400" style="border: 1px solid #ccc;"></canvas>

<script src="../../script/fabric.js"></script>
<script>

  let canvas = new fabric.Canvas('canvasBox', {
    interactive: false // 隐藏交互模式
  })

  let rect = new fabric.Rect({
    top: 60,
    left: 60,
    width: 60,
    height: 60,
    fill: '#08d9d6'
  })

  canvas.add(rect)

</script>
</body>
</html>